import Vue from "vue";
//导入路由
import VueRouter from 'vue-router';
Vue.use(VueRouter);

//导入头部组件
import { Header } from "mint-ui";
Vue.component(Header.name,Header);

//导入轮播组件
import { Swipe,SwipeItem,Button,Lazyload } from "mint-ui";
Vue.component(Swipe.name, Swipe);
Vue.component(SwipeItem.name, SwipeItem);
Vue.component(Button.name, Button);
Vue.use(Lazyload);
import "mint-ui/lib/style.css";

//时间过滤器 安装 npm i moment -D
import moment from 'moment';
Vue.filter("dateFormat",function (dataScr,pattern="YYYY-MM-DD HH:mm:ss") {
    return  moment(dataScr).format(pattern);
});

//导入VueResource 安装 npm i vue-resource -D
import VueResource from "vue-resource";
Vue.use(VueResource);
Vue.http.options.root="./localData";

//npm i vue-preview –D
import VuePreview from "vue-preview";
Vue.use(VuePreview);


//导入mui.css
import './lib/mui/css/mui.min.css';
import './lib/mui/css/icons-extra.css';

import "vue-preview/dist/vue-preview.min.js";

//=============================================================
import './css/indes.css';
import app from "./app.vue";
import vr from './router';


var vn=new Vue({
    el:'#app',
    data:{},
    methods:{},
    render: h=>h(app),
    router:vr
});
